package com.treasure.mall.biz.dto.live;

import com.treasure.mall.biz.entity.live.LiveRobotPO;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

/**
 *
 * +---------------------------------------------------------
 * * @package: com.treasure.mall.biz.dto.live
 * * @author: guomw (guomwchen@foxmail.com)
 * * @date: 2020/6/23 13:47
 * * @since: V1.0.0
 * +---------------------------------------------------------
 * 注意：本内容仅限于内部传阅，禁止外泄以及用于其他的商业目的
 * Copyright 2019-2022 com.treasure.mall.biz.dto.live Inc. All rights reserved.
 */
@Data
@ApiModel("用户消息等级实体")
public class LiveMessageUserLevel {

    /**
     * 用户等级编号 0~9
     */
    @ApiModelProperty(value = "用户等级编号 0~9", required = true)
    private int level;
    /**
     * 等级名称
     */
    @ApiModelProperty(value = "等级名称", required = true)
    private String name;

    public String getFullLevelName() {
        return "LV " + level + " " + name;
    }


    public LiveMessageUserLevel(LiveRobotPO robotPO) {
        this.level = robotPO.getLevel();
        this.name = robotPO.getLevelName();
    }

    public LiveMessageUserLevel() {
        this.level = 0;
        this.name = "Zlive";
    }

    public LiveMessageUserLevel(int level, String name) {
        this.level = level;
        this.name = name;
    }
}
